package com.driver.system.controller.form;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.math.BigDecimal;

/**
 * @author 老顾
 * @apiNote
 * @since 2024/4/1
 */
@Data
public class SearchWalletPaymentByPageForm {

    @NotNull(message = "page不能为空")
    @Min(value = 1, message = "page不能小于1")
    @Schema(description = "页数")
    private Integer page;

    @NotNull(message = "length不能为空")
    @Range(min = 10, max = 50, message = "length必须在10~50之间")
    @Schema(description = "每页记录数")
    private Integer length;

    @Pattern(regexp = "^1\\d{10}$", message = "tel内容不正确")
    @Schema(description = "电话")
    private String tel;

    /**
     * 1未支付，2已支付，3已到账
     */
    @Min(value = 1, message = "status不能小于1")
    private Integer status;

    /**
     * 司机ID
     */
    private Long driverId;

    /**
     * 金额
     */
    private BigDecimal amount;

    /**
     * 1充值，2奖励，3补贴
     */
    private Byte type;

    /**
     * 备注信息
     */
    private String remark;

    /**
     * 创建时间
     */
    private String createTime;
}
